package org.cuatrovientos.javakart;

import java.util.Vector;

public class Race {
	
	private Circuit circuit;
	private Vector<Vehicle> vehicles;
	private String name;

	public Race(String name, Circuit circuit) {
		this.name = name;
		this.circuit = circuit;
	}
	
	public void addVehicle (Vehicle vehicle) {
		vehicles.add(vehicle);
	}
	public Vehicle race () {
		Vehicle winner = null;
		for (int i = 0; i < vehicles.size();i++) {
			vehicles.elementAt(i).move();
			return winner;
		}
	}
}
